<template>
	<view class="page">
		<view class="u-flex" style="flex-wrap: wrap;">
			<view v-for="(item,index) in list" :key="index" class="u-padding-20"
				style="background: #fff;width: 330rpx;border-radius: 20rpx;margin: 20rpx ;" @click="go(item)">
				<image :src="item.cover" style="width: 100%;height: 200rpx;border-radius: 20rpx;" mode="aspectFill">
				</image>
				<view class="u-text-center u-margin-top-20">{{item.title}}</view>
			</view>
		</view>
<u-loadmore :status="status" />
	</view>
</template>

<script>
	import loader from '@/common/loadPage.js';
	export default {
		mixins: [loader],
		data() {

			return {
				tabbar: [],
				nav: [],
				current: 0,
				list: [],
				initial: {
					geturl: "/api/index/news",
					parm: {

					},
					isPage: true
				},




			}
		},
		async onLoad() {

			this.getGoods()
		},
		methods: {

go(item){
	uni.navigateTo({
		url:'./detail?id='+item.id
	})
}
		}
	}
</script>


<style>
	.page {
		background: #F1F1F1;
		min-height: 100vh;
	}

	.list {
		background: #fff;
		width: 700rpx;
		margin: 20rpx auto;
		padding: 20rpx;
	}
</style>
